SLES 12
Sponsored Link

Install Apache2
2015/11/28
 
Install Apache2 to configure Web Server. HTTP uses 80/TCP.
[1] Install Apache2.
www:~ #
zypper -n install apache2
[2] Configure Apache2.
www:~ #
vi /etc/sysconfig/apache2
# line 192: change to own admin email

APACHE_SERVERADMIN="
webmaster@srv.world
"
# line 209: change to own hostname

APACHE_SERVERNAME="
www.srv.world
"
# line 288: change

APACHE_SERVERTOKENS="
Prod
"
www:~ #
vi /etc/apache2/httpd.conf
# line 186: add file name that it can access only with directory's name

DirectoryIndex
index.html index.htm
www:~ #
systemctl start apache2

www:~ #
systemctl enable apache2

[3] Create a HTML test page and access to it from client PC with web browser. It's OK if following page is shown.
www:~ #
vi /srv/www/htdocs/index.html
<html>
<body>
<div style="width: 100%; font-size: 40px; font-weight: bold; text-align: center;">
Test Page
</div>
</body>
</html>
 
Tweet